<%@ page language="java" pageEncoding="utf-8"%>
<%@ taglib prefix="s" uri="/struts-tags"%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
		<title>客户列表</title>
		<link rel="stylesheet" type="text/css" href="../resource/css/base.css">
		<script type="text/javascript" src="../resource/js/prototype.js"></script>
		<s:actionmessage/>
	</head>
	<script type="text/javascript">
		function doSelect(){
			var form = document.forms[0];
			var data = {};
			data.mark = '<s:property value="mark"/>';
			//调用封装的方法，获取选择项的值
			data.items = getChecked();
			if(data["items"].length <= 0){
				alert('请选择客户信息.');
				return;
			}
			parent.setForm(data);
			parent.ClosePop();
		}
	</script>
	<body  oncontextmenu="return false;" leftmargin="8" topmargin="8" style="overflow: hidden">
		<!--  搜索列表  -->
		<s:form name="infoForm" action="popupLoadClient">
			<s:hidden name="mark"/>
			<table width='98%' border='0' cellpadding='1' cellspacing='1' bgcolor='#CBD8AC' align="center" style="margin-top: 8px">
				<tr bgcolor='#EEF4EA'>
					<td align='center'>
						<table width="98%" height="26" border='0' cellpadding='0'
							cellspacing='0'>
							<tr>
								<td width="10%" align="right">
									单位名称:
								</td>
								<td width="15%" align="left">
									<s:textfield name="clientName" />
								</td>
								<td width="10%" align="right">
									&nbsp;联系人:
								</td>
								<td width="15%" align="left">
									<s:textfield name="linkman" />
								</td>
								<td width="10%" align="center">
									<input type="image" src="../resource/image/search.gif"
										height="20" border="0" class="np" onclick="javascript:document.forms[0].submit();" />
								</td>
							</tr>
						</table>
					</td>
				</tr>
			</table>
			<!--  内容列表   -->
			<table width="98%" border="0" cellpadding="2" cellspacing="1"
				bgcolor="#D1DDAA" align="center" style="margin-top: 8px">
				<tr bgcolor="#E7E7E7">
					<td height="24" colspan="10">
						&nbsp;客户列表&nbsp;
					</td>
				</tr>
				<!-- 表头 -->
				<tr align="center" bgcolor="#FAFAF1" height="22">
					<td width="5%">
						选择
					</td>
					<td width="8%">
						联系人
					</td>
					<td width="18%">
						单位名称
					</td>
					<td width="30%">
						单位地址
					</td>
					<td width="14%">
						联系电话
					</td>
				</tr>
				<s:iterator value="clients" status="vo">
					<!-- 信息 -->
					<tr align='center' bgcolor="#FFFFFF"
						onMouseMove="javascript:this.bgColor='#FCFDEE';"
						onMouseOut="javascript:this.bgColor='#FFFFFF';" height="22">
						<td><input name="id" type="radio" id="id"value="<s:property value="clientId"/>" class="np"></td>
						<td><s:property value="linkman" /></td>
						<td><s:property value="clientName"/></td>
						<td><s:property value="address"/></td>
						<td><s:property value="phone"/></td>
					</tr>
				</s:iterator>
			</table>
			<table width="98%" border="0" cellpadding="1" cellspacing="1" bgcolor="#CBD8AC" style="position:absolute; bottom: 10px; margin-left: 1%;">
				<!-- 引用统一的操作、分页功能页面
					 其中的url参数a、q、d分别用来传入增、查、删功能的action -->
				<jsp:include page="/WEB-INF/pages/frame/popupPage.jsp?q=popupLoadClient&cols=10"/>
			</table>
		</s:form>
	</body>
</html>
